const HtmlWebpackPlugin = require('html-webpack-plugin');

module.exports = {
    entry: {
        index: ['./src/scss/swiper.min.css', './src/scss/index.scss', './src/font/iconfont.css', './src/js/swiper.min.js', './src/js/index.js'],
        about: ['./src/scss/about.scss'],
        unit: ['./src/scss/unit.scss'],
        group: ['./src/scss/group.scss'],
        contact: ['./src/scss/contact.scss'],
        new: ['./src/scss/new.scss'],
        business: ['./src/scss/business.scss'],
        friend: ['./src/scss/friend.scss'],
        voting: ['./src/scss/swiper.min.css', './src/scss/voting.scss', './src/js/swiper.min.js', './src/js/index.js'],

    },
    plugins: [
        new HtmlWebpackPlugin({
            template: "./src/html/voting.html",
            filename: "voting.html",
            chunks: ["voting"]
        }),
        new HtmlWebpackPlugin({
            template: "./src/html/business.html",
            filename: "business.html",
            chunks: ["business"]
        }),
        new HtmlWebpackPlugin({
            template: "./src/html/friend.html",
            filename: "friend.html",
            chunks: ["friend"]
        }),
        new HtmlWebpackPlugin({
            template: "./src/html/index.html",
            filename: "index.html",
            chunks: ["index"]
        }),
        new HtmlWebpackPlugin({
            template: "./src/html/about.html",
            filename: "about.html",
            chunks: ["about"]
        }),
        new HtmlWebpackPlugin({
            template: "./src/html/unit.html",
            filename: "unit.html",
            chunks: ["unit"]
        }), new HtmlWebpackPlugin({
            template: "./src/html/contact.html",
            filename: "contact.html",
            chunks: ["contact"]
        }),
        new HtmlWebpackPlugin({
            template: "./src/html/group.html",
            filename: "group.html",
            chunks: ["group"]
        }),
        new HtmlWebpackPlugin({
            template: "./src/html/new.html",
            filename: "new.html",
            chunks: ["new"]
        }),

    ]
}